//
//  expage18.c
//  denissritchie
//
//  Created by Amit Jha on 8/12/12.
//  Copyright (c) 2012 Amit Jha. All rights reserved.
//

#include <stdio.h>


/* count characters in input; 1st version*/



int main(){
    
    long nc;
    
    nc = 0;
    while (getchar() != EOF) {
        ++nc;
        
    }
    printf("%ld\n",nc);
}